<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
	pageEncoding="ISO-8859-1"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<script type="text/javascript"
	src="http://code.jquery.com/jquery-1.8.3.js"></script>
<link href="<c:url value='/css/Team2CSS.css'/>" rel="stylesheet"
	type="text/css" />

<script>
	$(document)
			.ready(
					function() {
						$("#login")
								.submit(
										function() {
											if ($.trim($("#id_txt").val()) == ""
													|| $.trim($("#password_p")
															.val()) == "") {
												alert("Please verify your UserID and Password.");
												//window.location.replace("Login.jsp");
												clear($("#id_txt").val()
														+ $("#password_p")
																.val());
												return false;
											}
										});
						$("input").focus(function() {
							$(this).css("background-color", "#FFFACD");
						});
						$("input").blur(function() {
							$(this).css("background-color", "#ffffff");
						});
					});
</script>

<title>Facility Booking System Login</title>
</head>

<body>
<%@ include file="header.jsp" %>	
<!-- 	<table><tr><td width=20%></td><td width=60%> -->
<center>
<h3>Please Sign In</h3>
	<form id="login" method="post" action="/JavaCA/login">
		<div>
			<c:if test="${!empty error2 }">
				<p style="color: red;">${error2 }</p>
			</c:if>
			<c:if test="${!empty error3 }">
				<p style="color: red;">${error3 }</p>
			</c:if>
			<c:if test="${!empty error4 }">
				<p style="color: red;">${error4 }</p>
			</c:if>
		</div>
		<div>
			<table>
				<tr>
					<td>User ID:&nbsp;&nbsp;&nbsp;</td>
					<td><input type="text" name="userId" maxlength="8" size="40"
						id="id_txt" /></td>
					<c:if test="${!empty error1 }">
			&nbsp;&nbsp;&nbsp;<td style="color: red;">${error1}</td>
					</c:if>
				</tr>
				<tr>
					<td>Password:&nbsp;&nbsp;&nbsp;</td>
					<td><input type="password" name="password" size="40"
						id="password_p" /></td>
				</tr>
				<tr>
					<td><br> <input type="submit" name="button_submit"
						value="Submit" id="submit_btn" /></td>
					<td><br> <input type="reset" name="button_reset"
						value="Reset" /></td>
					<td><br> <a href="ForgotPassword.jsp" id="forget_link">Forgot
							Password?</a></td>
				</tr>
			</table>
		</div>
	</form>
	</center>
<!-- 	</TD><TD WIDTH=20%></TD></TR></TABLE> -->
<%@ include file="footer.jsp" %>
</body>
</html>